package com.um.jdy.platform.activity.entity.dto;

import com.um.springboot.starter.orm.params.PageDTO;
import com.um.springboot.starter.orm.params.PageParams;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

/**
 * @author 邓南辉
 * 日期 2023/6/21
 * 版权所有 广州优匠科技有限公司
 */
@Data
public class DiscountsPageDTO extends PageDTO {


    @ApiModelProperty(value = "活动名称")
    private String title;

    @ApiModelProperty(value = "是否生效")
    private String status;

    @Override
    public PageParams toPageParams() {
        PageParams pageParams = toPageParams(new String[]{"title","status"},
                new String[]{"title","status"});

        pageParams.getCondition().put("orderby","create_time desc");
        return pageParams;
    }

}
